
import java.util.Vector;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Administrator
 */
public class VectorDemo3 {
    public static void main(String[] args) {
        Vector v2 = new Vector();
        for (int i = 1 ; i <= 10 ; i++){
        v2.add("第" +i+ "个小孩");
        
    }
     System.out.println(v2);
     
     for(;;){
         if (v2.size()==1) break;
         for(int k=0;k<2;k++){
             v2.add(v2.get(0));
             v2.remove(0);
             
             System.out.print("当前的容器是：");
             System.out.println(0);
             
             v2.remove(0);
         }
       System.out.print("最后的容器是：");
             System.out.println(0);  
     }
    }

}
